#include "derived.h"
#include "base.h"     // 直接包含base.h来测试export_include_paths继承
#include <iostream>

int main() {
    std::cout << "=== Export Include Paths Inheritance Test ===" << std::endl;
    std::cout << "Testing if derived_lib correctly inherits base_lib's export_include_paths" << std::endl;
    std::cout << std::endl;
    
    // 初始化
    std::cout << "--- Initialization ---" << std::endl;
    Derived::initializeDerived();
    std::cout << std::endl;
    
    // 创建对象
    std::cout << "--- Creating Objects ---" << std::endl;
    Derived::DerivedClass derived;
    
    // 创建几个BaseClass实例并添加到DerivedClass
    Base::BaseClass base1;
    base1.setValue(10);
    derived.addBase(base1);
    
    Base::BaseClass base2;
    base2.setValue(20);
    derived.addBase(base2);
    
    Base::BaseClass base3;
    base3.setValue(30);
    derived.addBase(base3);
    
    std::cout << std::endl;
    
    // 处理所有对象
    std::cout << "--- Processing ---" << std::endl;
    derived.processAll();
    std::cout << "Total value: " << derived.getTotalValue() << std::endl;
    std::cout << std::endl;
    
    // 清理
    std::cout << "--- Cleanup ---" << std::endl;
    Derived::cleanupDerived();
    
    std::cout << std::endl;
    std::cout << "=== Test Completed Successfully ===" << std::endl;
    std::cout << "If this program compiled and ran, it means:" << std::endl;
    std::cout << "1. derived_lib successfully inherited base_lib's export_include_paths" << std::endl;
    std::cout << "2. main.cpp can directly include base.h through derived_lib dependency" << std::endl;
    
    return 0;
}